export * from './auth'
export * from './users'
export * from './vehicles'
export * from './personnel'
export * from './groups'
export * from './areas'
export * from './dashboard'
export * from './dictionaries'
export * from './workOrders'
export * from './materials'
export * from './materialUsage'
export * from './formTemplates'
export * from './permissions'
export * from './systemConfig'
export * from './materialCategories'

// 统一导出API模块
export { authApi } from './auth'
export { usersApi } from './users'
export { vehiclesApi } from './vehicles'
export { personnelApi } from './personnel'
export { groupsApi } from './groups'
export { areasApi } from './areas'
export { dashboardApi } from './dashboard'
export { dictionariesApi } from './dictionaries'
export { workOrdersApi } from './workOrders'
export { materialsApi } from './materials'
export { materialUsageApi } from './materialUsage'
export { formTemplatesApi } from './formTemplates'
export { permissionsApi } from './permissions'
export { systemConfigApi } from './systemConfig'
export { materialCategoriesApi } from './materialCategories'

// 默认导出，兼容 import api from '@/api' 的用法
import { workOrdersApi } from './workOrders'
import { materialsApi } from './materials'
import { materialUsageApi } from './materialUsage'
import { usersApi } from './users'
import { areasApi } from './areas'
import { authApi } from './auth'
import { dashboardApi } from './dashboard'
import { vehiclesApi } from './vehicles'
import { personnelApi } from './personnel'
import { groupsApi } from './groups'
import { dictionariesApi } from './dictionaries'
import { formTemplatesApi } from './formTemplates'
import { permissionsApi } from './permissions'
import { systemConfigApi } from './systemConfig'
import { materialCategoriesApi } from './materialCategories'

const api = {
  // 工单相关
  ...workOrdersApi,
  // 材料相关
  ...materialsApi,
  // 材料使用记录
  ...materialUsageApi,
  // 用户相关
  ...usersApi,
  // 区域相关
  ...areasApi,
  // 认证相关
  ...authApi,
  // 仪表盘
  ...dashboardApi,
  // 车辆相关
  ...vehiclesApi,
  // 人员相关
  ...personnelApi,
  // 组织相关
  ...groupsApi,
  // 字典相关
  ...dictionariesApi,
  // 表单模板
  ...formTemplatesApi,
  // 权限相关
  ...permissionsApi,
  // 系统配置
  ...systemConfigApi,
  // 材料分类
  ...materialCategoriesApi
}

export default api